﻿namespace RialternativeSample.Server.NorthwindService
{
    using System.ServiceModel.DomainServices.Hosting;
    using Rialternative.DescriptionProvider;
    using Rialternative.DomainService;

    [EnableClientAccess()]
    [EntityDomain(typeof(Customers),
                  EntityDomainOperations.All,
                  InsertRequiresRole = new string[] { "CustomerManager", "Admin" },
                  UpdateRequiresRole = new string[] { "CustomerManager" },
                  DeleteRequiresRole = new string[] { "CustomerManager" })]
    [EntityDomain(typeof(Products),
                  EntityDomainOperations.Query | EntityDomainOperations.Update,
                  RequiresAuthentication = EntityDomainOperations.Update)]
    [EntityDomain(typeof(Employees), EntityDomainOperations.Query)]
    [EntityDomainServiceDescriptionProvider(typeof(NorthwindEntities))]
    public class NorthwindService : RepositoryDomainService
    {
    }
}


